import 'package:flutter/material.dart';

class InputWidget extends StatelessWidget {
  final String hint;
  final ValueChanged<String>? valueChanged;
  final bool obscureText;
  final TextInputType? textInputType;

  const InputWidget(this.hint,
      {super.key,
      this.valueChanged,
      this.obscureText = false,
      this.textInputType});

  @override
  Widget build(BuildContext context) {
    return Column(
      children: [_input()],
    );
  }

  TextField _input() {
    return TextField(
      onChanged: valueChanged,
      obscureText: obscureText,
      decoration: InputDecoration(
          hintText: hint,
          hintStyle: const TextStyle(fontSize: 20, color: Colors.white60),
          border: InputBorder.none),
      autofocus: true,
      style: const TextStyle(fontSize: 20, color: Colors.white),
    );
  }
}
